package com.example.demo.repository;

import com.example.demo.entity.Student;
import org.springframework.data.domain.Sort;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.repository.PagingAndSortingRepository;

import java.util.List;

public interface StudentRepository extends JpaRepository<Student, Integer> {

    public List<Student> findByAgeBefore(Integer age);

    public List<Student> findByAgeBefore(Integer age, Sort sort);
}
